/*
 * Day.java
 *
 * Created on August 15, 2006, 11:13 AM
 *
 * To change this template, choose Tools | Template Manager
 * and open the template in the editor.
 */

package calendarapplication;

/**
 *
 * @author eddie.dillon
 */
import java.util.*;

public class Day {
    
    public Day(){
    }
    
    public Day(Calendar cal) {
        WeekDayName(cal);
    }
    
    public String WeekDayName(Calendar cal) {
        String retDay = "";
        //int weekDay = cal.DAY_OF_WEEK;
        int weekDay = cal.get(Calendar.DAY_OF_WEEK);
        switch (weekDay) {
            case 1: retDay = "Sunday"; break;
            case 2: retDay = "Monday"; break;
            case 3: retDay = "Tuesday"; break;
            case 4: retDay = "Wednesday"; break;
            case 5: retDay = "Thursday"; break;
            case 6: retDay = "Friday"; break;
            case 7: retDay = "Saturday"; break;
        }
        return retDay;
    }
    
}
